package simpleSpring.service;

import simpleSpring.spring.*;

/**
 * @author caihe
 * @date 2022/10/24 13:42
 */
@Component()
@Scope(Scope.SCOPE_SINGLETON)
public class UserService implements UserInterface, BeanNameAware, InitializingBean {
    @Autowired
    private OrderService orderService;
    
    private String beanName;

    @Override
    public void setBeanName(String beanName) {
        System.out.println("userService " + beanName);
    }

    @Override
    public void afterPropertiesSet() {
        System.out.println("afterPropertiesSet");
    }

    @Override
    public void userServiceTest() {
        System.out.println(orderService);
    }
    
}
